/**
 * Created by wlc on 2018/9/16.
 */

/**
 * 全局变量
 */
//markdown
var showEditor;

//notice
var notyfy;

/**
 * 变量与对象初始化
 */
window.onload = function (){
    //通知栏
    notyfy = new Notyf();
    //判断打开文档的用户是否是该文档的编写者,如果不是，则删除编写功能
    var fileAuthor = $('.doc-author')[0].innerText;
    var sysUser = $('.user_name')[0].innerText;
    if(fileAuthor.indexOf(sysUser) === -1){
        $('#operate-content')[0].remove('.doc-edit');
    }
};